package jee.boot.module.config;

import jee.boot.module.mail.sender.MailTaskHandler;
import jee.boot.entity.auth.ModelData;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;

@Component
public class MailConfigNew {

    @Autowired
    private PrintMailPostInterceptor printMailPostInterceptor;
    @Autowired
    private MailTaskHandler taskHandler;

    @PostConstruct
    public void customerMailTaskHandler() {
        taskHandler.addPostInterceptor(printMailPostInterceptor);// 自定义的邮件后置处理器

    }

    public static void main(String[] args) {
        System.out.println(new ModelData().getFindListSql());
    }
}
